home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 10528 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: news.lpr.carel.fi!usenet
  2. From: Ari Lukumies <aril@cmt.lpr.mail.carel.fi>
  3. Newsgroups: comp.lang.c++,comp.lang.c
  4. Subject: Re: debug before main()
  5. Date: Thu, 07 Mar 1996 16:05:15 +0200
  6. Organization: Carelcomp Forest
  7. Message-ID: <313EED1B.26B1@cmt.lpr.mail.carel.fi>
  8. References: <Pine.SOL.3.91.960305171701.17346B-100000@hamlet.uncg.edu>
  9. NNTP-Posting-Host: renoir.cclahti.carel.fi
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 2.0 (WinNT; I)
  14.  
  15. QIAN . ZHONG wrote:
  16. >  Hi, folks:
  17. >  What is the good way to debug the program before main(), I am using Borland
  18. > compiler, which generate a map file, and show the program entry point is
  19. > 0000:0000, relative memory start point,
  20. > how to load the program and start debug from 0000:0000 ?
  21.  
  22. Just load the program into debugger and bring up the disassembly window. You can 
  23. step through the assembly code shown there. Or, the better way, some Borland 
  24. systems come with the sources to the library startup code. Compile it with debug 
  25. information and link that into your program instead of the traditional (c0l,cw0l 
  26. etc) modules. Now, you can step through that code as if it were code you wrote. 
  27. Note that most (if not all) of it is in assembly.
  28.  
  29. Later,
  30.  AriL
  31. -- 
  32. All my opinions are mine and mine alone.
  33.